/**
 * Copyright (C) 2013 SHANGHAI VOLKSWAGEN, All rights reserved.
 * License version 1.0, a copy of which has been included with this.
 *
 * @File name：com.bwie.system.controller.SystemController
 * @Create on：2024/3/22
 * @Author：liuchang
 */
package com.bwie.patient.controller;

import com.bwie.common.domain.Dept;
import com.bwie.common.domain.Evaluate;
import com.bwie.common.domain.Receive;
import com.bwie.common.domain.User;
import com.bwie.common.domain.response.DeptResponse;
import com.bwie.common.domain.response.DescribeResponse;
import com.bwie.common.domain.response.MedicResponse;
import com.bwie.common.result.Result;
import com.bwie.patient.service.PatientService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>ClassName：SystemController</p >
 * <p>Description：</p >
 * <p>Author：liuchang</p >
 * <p>Date：2024/3/22</p >
 * @author 任旭浩
 */
@RestController
public class PatientController {
    @Autowired
    private PatientService patientService;
    /**
     * 查找所有的科室
     */
    @PostMapping("/patientList")
    private Result<List<Dept>> patientList(){
        return patientService.patientList();
    }
    /**
     * 查找医院对应的科室
     */
    @PostMapping("/patientsList/{id}")
    private Result<List<DeptResponse>> patientsList(@PathVariable Integer id){
        return patientService.patientsList(id);
    }
    /**
     * 查找科室中的医生
     */
    @PostMapping("/medicList")
    private Result<List<User>> medicList(@RequestBody MedicResponse medicResponse){
        return patientService.medicList(medicResponse);
    }
    /**
     * 添加接诊列表
     */
    @PostMapping("/lineupInsert")
    private Result lineupInsert(@RequestBody DescribeResponse describeResponse){
        return patientService.lineupInsert(describeResponse);
    }
    /**
     * 查询接诊列表
     */
    @PostMapping("/lineupList")
    private Result<List<Receive>> lineupInsert(){
        return patientService.lineupList();
    }
    /**
     * 查询医生信息
     */
    @PostMapping("/doctorList")
    private Result<List<User>> doctorList(){
        return patientService.doctorList();
    }
    /**
     * 对医生进行评价
     */
    @PostMapping("/EvaluateInsert")
    private Result evaluateInsert(@RequestBody Evaluate evaluate){
        return patientService.evaluateInsert(evaluate);
    }


}
